﻿using Plugins.Base.Historical;
using StockModel;
using TrixPlugin.Common;

namespace TrixPlugin.Historical
{
	internal class HistoricalEngineParallel : Plugins.Base.Historical.HistoricalEngineParallelBase
	{
		#region Properties

		public new HistoricalSettings Settings
		{
			get
			{
				return (HistoricalSettings)base.Settings;
			}
			set
			{
				base.Settings = value;
			}
		}

		#endregion

		#region Public Methods

		public HistoricalEngineParallel(QuotationDataSource quotationDataSource, RawStockDataSource rawStockDataSource) : base(quotationDataSource, rawStockDataSource)
		{
			
		}

        protected override HistoricalDayProcessorBase CreateDayProcessor()
        {
            HistoricalDayProcessorBase processor = new HistoricalDayProcessorBase(base.QuotationDataSource, base.RawStockDataSource, this.Settings.HourOptions, this.Settings.StockParameters, this.Settings.StrategyControlData.Inverted);
			DecisionEngineData decisionEngineData = new DecisionEngineData();
            DecisionEngine decisionEngine = new DecisionEngine(decisionEngineData, processor.DataFeeder.Data, this.Settings.StrategyControlData, this.Settings.HourOptions, processor.OperationManager);

            return processor;
        }

		#endregion
	}
}
